<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Eigen: Eigen::Stride&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(function() { init_search(); });
/* @license-end */
</script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="eigendoxy.css" rel="stylesheet" type="text/css">
<!--  -->
<script type="text/javascript" src="eigen_navtree_hacks.js"></script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Eigen_Silly_Professor_64x64.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname"><a href="http://eigen.tuxfamily.org">Eigen</a>
   &#160;<span id="projectnumber">3.4.90 (git rev 67eeba6e720c5745abc77ae6c92ce0a44aa7b7ae)</span>
   </div>
  </td>
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.svg"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
          </span>
        </div>
</td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classEigen_1_1Stride.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="classEigen_1_1Stride-members.html">List of all members</a> &#124;
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Eigen::Stride&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt; Class Template Reference<div class="ingroups"><a class="el" href="group__DenseMatrixManipulation__chapter.html">Dense matrix and array manipulation</a> &raquo; <a class="el" href="group__DenseMatrixManipulation__Reference.html">Reference</a> &raquo; <a class="el" href="group__Core__Module.html">Core module</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt;<br />
class Eigen::Stride&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;</h3>

<p>Holds strides information for <a class="el" href="classEigen_1_1Map.html" title="A matrix or vector expression mapping an existing array of data.">Map</a>. </p>
<p>This class holds the strides information for mapping arrays with strides with class <a class="el" href="classEigen_1_1Map.html" title="A matrix or vector expression mapping an existing array of data.">Map</a>.</p>
<p>It holds two values: the inner stride and the outer stride.</p>
<p>The inner stride is the pointer increment between two consecutive entries within a given row of a row-major matrix or within a given column of a column-major matrix.</p>
<p>The outer stride is the pointer increment between two consecutive rows of a row-major matrix or between two consecutive columns of a column-major matrix.</p>
<p>These two values can be passed either at compile-time as template parameters, or at runtime as arguments to the constructor.</p>
<p>Indeed, this class takes two template parameters: </p><dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">OuterStrideAtCompileTime_</td><td>the outer stride, or Dynamic if you want to specify it at runtime. </td></tr>
    <tr><td class="paramname">InnerStrideAtCompileTime_</td><td>the inner stride, or Dynamic if you want to specify it at runtime.</td></tr>
  </table>
  </dd>
</dl>
<p>Here is an example: </p><div class="fragment"><div class="line"><span class="keywordtype">int</span> array[24];</div>
<div class="line"><span class="keywordflow">for</span>(<span class="keywordtype">int</span> i = 0; i &lt; 24; ++i) array[i] = i;</div>
<div class="line">cout &lt;&lt; Map&lt;MatrixXi, 0, Stride&lt;Dynamic,2&gt; &gt;</div>
<div class="line">         (array, 3, 3, Stride&lt;Dynamic,2&gt;(8, 2))</div>
<div class="line">     &lt;&lt; endl;</div>
</div><!-- fragment --><p> Output: </p><pre class="fragment"> 0  8 16
 2 10 18
 4 12 20
</pre><p>Both strides can be negative. However, a negative stride of -1 cannot be specified at compile time because of the ambiguity with Dynamic which is defined to -1 (historically, negative strides were not allowed).</p>
<p>Note that for compile-time vectors (ColsAtCompileTime==1 or RowsAtCompile==1), the inner stride is the pointer increment between two consecutive elements, regardless of storage layout.</p>
<dl class="section see"><dt>See also</dt><dd>class <a class="el" href="classEigen_1_1InnerStride.html" title="Convenience specialization of Stride to specify only an inner stride See class Map for some examples.">InnerStride</a>, class <a class="el" href="classEigen_1_1OuterStride.html" title="Convenience specialization of Stride to specify only an outer stride See class Map for some examples.">OuterStride</a>, <a class="el" href="group__TopicStorageOrders.html">Storage orders</a> </dd></dl>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:abf4da87f52b80de840f035e133c9a201"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Eigen::Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a></td></tr>
<tr class="separator:abf4da87f52b80de840f035e133c9a201"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a060385a0db5a0cefa980fc418eeb36b7"><td class="memItemLeft" align="right" valign="top">EIGEN_CONSTEXPR <a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#a060385a0db5a0cefa980fc418eeb36b7">inner</a> () const</td></tr>
<tr class="separator:a060385a0db5a0cefa980fc418eeb36b7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5a924f8d6e8f5804a116e3d3077b26f0"><td class="memItemLeft" align="right" valign="top">EIGEN_CONSTEXPR <a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#a5a924f8d6e8f5804a116e3d3077b26f0">outer</a> () const</td></tr>
<tr class="separator:a5a924f8d6e8f5804a116e3d3077b26f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9434e5cb579fcd452a16d96e16e2eb3e"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#a9434e5cb579fcd452a16d96e16e2eb3e">Stride</a> ()</td></tr>
<tr class="separator:a9434e5cb579fcd452a16d96e16e2eb3e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a55c707ce7acfb30b2e2ed866b290930e"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#a55c707ce7acfb30b2e2ed866b290930e">Stride</a> (const <a class="el" href="classEigen_1_1Stride.html">Stride</a> &amp;other)</td></tr>
<tr class="separator:a55c707ce7acfb30b2e2ed866b290930e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae46837b5048c1a9dfca7cccc443cbd41"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1Stride.html#ae46837b5048c1a9dfca7cccc443cbd41">Stride</a> (<a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a> outerStride, <a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a> innerStride)</td></tr>
<tr class="separator:ae46837b5048c1a9dfca7cccc443cbd41"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Member Typedef Documentation</h2>
<a id="abf4da87f52b80de840f035e133c9a201"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abf4da87f52b80de840f035e133c9a201">&#9670;&nbsp;</a></span>Index</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Eigen::Index</a> <a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::<a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000005">Deprecated:</a></b></dt><dd>since <a class="el" href="namespaceEigen.html" title="Namespace containing all symbols from the Eigen library.">Eigen</a> 3.3 </dd></dl>

</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a9434e5cb579fcd452a16d96e16e2eb3e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9434e5cb579fcd452a16d96e16e2eb3e">&#9670;&nbsp;</a></span>Stride() <span class="overload">[1/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::<a class="el" href="classEigen_1_1Stride.html">Stride</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Default constructor, for use when strides are fixed at compile time </p>

</div>
</div>
<a id="ae46837b5048c1a9dfca7cccc443cbd41"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae46837b5048c1a9dfca7cccc443cbd41">&#9670;&nbsp;</a></span>Stride() <span class="overload">[2/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::<a class="el" href="classEigen_1_1Stride.html">Stride</a> </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a>&#160;</td>
          <td class="paramname"><em>outerStride</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a>&#160;</td>
          <td class="paramname"><em>innerStride</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Constructor allowing to pass the strides at runtime </p>

</div>
</div>
<a id="a55c707ce7acfb30b2e2ed866b290930e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a55c707ce7acfb30b2e2ed866b290930e">&#9670;&nbsp;</a></span>Stride() <span class="overload">[3/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::<a class="el" href="classEigen_1_1Stride.html">Stride</a> </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classEigen_1_1Stride.html">Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt; &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Copy constructor </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a060385a0db5a0cefa980fc418eeb36b7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a060385a0db5a0cefa980fc418eeb36b7">&#9670;&nbsp;</a></span>inner()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">EIGEN_CONSTEXPR <a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a> <a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::inner </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>the inner stride </dd></dl>

</div>
</div>
<a id="a5a924f8d6e8f5804a116e3d3077b26f0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5a924f8d6e8f5804a116e3d3077b26f0">&#9670;&nbsp;</a></span>outer()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;int OuterStrideAtCompileTime_, int InnerStrideAtCompileTime_&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">EIGEN_CONSTEXPR <a class="el" href="classEigen_1_1Stride.html#abf4da87f52b80de840f035e133c9a201">Index</a> <a class="el" href="classEigen_1_1Stride.html">Eigen::Stride</a>&lt; OuterStrideAtCompileTime_, InnerStrideAtCompileTime_ &gt;::outer </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>the outer stride </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="Stride_8h_source.html">Stride.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespaceEigen.html">Eigen</a></li><li class="navelem"><a class="el" href="classEigen_1_1Stride.html">Stride</a></li>
    <li class="footer">Generated on Thu Apr 21 2022 13:07:56 for Eigen by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
